﻿using FieldTools.Client.Command;
using FieldTools.Client.ViewModel.Window;
using FieldTools.Util;
using MahApps.Metro.Controls;
using Microsoft.Extensions.DependencyInjection;

namespace FieldTools.Client.View.Window
{
    /// <summary>
    /// Login.xaml 的交互逻辑
    /// </summary>
    public partial class LoginWindow : MetroWindow, ITransientDependency
    {
        /// <summary>
        /// 是否已打开窗口（定义该静态属性后即表示当前窗口仅能打开一个）
        /// </summary>
        public static bool IsOpened { get; set; }
        /// <summary>
        /// 构造
        /// </summary>
        public LoginWindow(LoginViewModel viewModel)
        {
            InitializeComponent();
            this.DataContext = viewModel;
            WindowManager.Register<ToolsBox>("ToolsBox");
        }
    }
}
